让我们加入精灵控件。
- 添加 Left Key,Right Key,Up Key,Down Key 让你的精灵上下移动。
- 将一个 Collision with Other Sprite 拖动到你的事件内部。
- 将 Global Variable 拖动到碰撞事件中。将变量更改为 recycle_xp。
- 将 my_var 更改为 litter。更改 if 语句以测试 litter 是否在 recycle 列表。
To navigate the page using the TAB key, first press ESC to exit the code editor.